package com.chapter.sample.conf;

import com.alibaba.druid.pool.DruidDataSource;
import com.alibaba.druid.spring.boot3.autoconfigure.DruidDataSourceBuilder;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Bean;

/**
 * `社交用户`
 *
 * @author libo
 * @date 2022/02/15 09:45
 */
public class SampleCouponDataSourceConfiguration {

    @Bean(name = "sampleCouponDataSource", initMethod = "init")
    @ConfigurationProperties(prefix = "spring.datasource.druid.coupon")
    public DruidDataSource sampleCouponDataSource() {
        return DruidDataSourceBuilder.create().build();
    }

}
